import 'package:xin_he/generated/json/base/json_field.dart';
import 'package:xin_he/generated/json/xin_he_goods_specification_model_entity.g.dart';
import 'dart:convert';

@JsonSerializable()
class XinHeGoodsSpecificationModelEntity {
	String? id;
	String? fGoodsId;
	String? name;
	double? price;
	double? originalPrice;
	double? seckillPrice;
	double? groupPurchasePrice;
	dynamic unit;
	dynamic remark;
	@JSONField(name: "version_num")
	dynamic versionNum;
	dynamic removed;
	dynamic createTime;
	dynamic updateTime;
	dynamic fCreateUserId;
	dynamic fUpdateUserId;
  bool isSelected = false;
	XinHeGoodsSpecificationModelEntity();

	factory XinHeGoodsSpecificationModelEntity.fromJson(Map<String, dynamic> json) => $XinHeGoodsSpecificationModelEntityFromJson(json);

	Map<String, dynamic> toJson() => $XinHeGoodsSpecificationModelEntityToJson(this);

	XinHeGoodsSpecificationModelEntity copyWith({String? id, String? fGoodsId, String? name, double? price, double? originalPrice, double? seckillPrice, double? groupPurchasePrice, dynamic unit, dynamic remark, dynamic versionNum, dynamic removed, dynamic createTime, dynamic updateTime, dynamic fCreateUserId, dynamic fUpdateUserId}) {
		return XinHeGoodsSpecificationModelEntity()
			..id= id ?? this.id
			..fGoodsId= fGoodsId ?? this.fGoodsId
			..name= name ?? this.name
			..price= price ?? this.price
			..originalPrice= originalPrice ?? this.originalPrice
			..seckillPrice= seckillPrice ?? this.seckillPrice
			..groupPurchasePrice= groupPurchasePrice ?? this.groupPurchasePrice
			..unit= unit ?? this.unit
			..remark= remark ?? this.remark
			..versionNum= versionNum ?? this.versionNum
			..removed= removed ?? this.removed
			..createTime= createTime ?? this.createTime
			..updateTime= updateTime ?? this.updateTime
			..fCreateUserId= fCreateUserId ?? this.fCreateUserId
			..fUpdateUserId= fUpdateUserId ?? this.fUpdateUserId;
	}

	@override
	String toString() {
		return jsonEncode(this);
	}
}